package com.zenchn.enums;

/**
 * 客户是否有效枚举
 * @author panbingqi
 * @date 2021/06/08 15:01
 */
public enum CustomerStatusEnum {

    /**
     * 有效
     **/
    EFFECTIVE("1","有效"),

    /**
     * 无效
     **/
    INVALID("0","无效");

    CustomerStatusEnum(String upgradeStatus, String appDesc) {
        this.upgradeStatus = upgradeStatus;
        this.appDesc = appDesc;
    }


    public static String getAppDesc(String upgradeStatus) {
        for (CustomerStatusEnum e : values()) {
            if (e.getUpgradeStatus().equals(upgradeStatus)) {
                return e.getAppDesc();
            }
        }
        return "";
    }

    /**
     * upgradeStatus
     **/
    private String upgradeStatus;
    /**
     * 设备中文描述
     **/
    private String appDesc;


    public String getUpgradeStatus() {
        return upgradeStatus;
    }

    public void setUpgradeStatus(String upgradeStatus) {
        this.upgradeStatus = upgradeStatus;
    }

    public String getAppDesc() {
        return appDesc;
    }

    public void setAppDesc(String appDesc) {
        this.appDesc = appDesc;
    }
}
